<?php
//$theme = array();
//$theme['description'] = 'test desc';
//$theme['keywords'] = 'test, only';
//$theme['filecss'] = array('a:c:table-style3');
//$theme['filejs'] = array('a:j:jquery.validationEngine-en3');
//$theme['footer'] = '<p>test foot</p>';
//$theme['jquery'] = 'test set';
//$this->theme->library->theme_lib->initialize($theme);
$this->theme->view('_head');

?>

<?php //print_r($profile);?><br />
<table class="btable">
    <tbody>
         <tr>
            <th><?php echo $this->lang->line('mem.60.id'); ?></th>
            <td><?php echo $profile->user_id?></td>
         </tr>
         <tr>
            <th><?php echo $this->lang->line('mem.61.user'); ?></th>
            <td><?php echo $profile->username?></td>
        </tr>
        <tr>
            <th><?php echo $this->lang->line('mem.62.email'); ?></th>
            <td><?php echo $profile->email?></td>
        </tr>
        <tr>
            <th><?php echo $this->lang->line('mem.63.group'); ?></th>
            <td><?php echo $group[$profile->memgroup]?>

            </td>
        </tr>
   
        
        <tr>
            <th><?php echo $this->lang->line('mem.86.last_ip'); ?></th>
            <td><?php echo $profile->last_ip?></td>
        </tr>
        <tr>
            <th><?php echo $this->lang->line('mem.87.last_login'); ?></th>
            <td><?php echo $profile->last_login?></td>
        </tr>
        <tr>
            <th><?php echo $this->lang->line('mem.88.created'); ?></th>
            <td><?php echo $profile->created?></td>
        </tr>
        <tr>
            <th><?php echo $this->lang->line('mem.89.modified'); ?></th>
            <td><?php echo $profile->modified?></td>
        </tr>
        <tr>
            <th colspan="2"><?php echo $this->lang->line('mem.81.profile'); ?></th>

        </tr>
        </tbody>
        <form action="<?php echo site_url('member/admin/change_profile/'.$profile->user_id)?>" method="post">

        <tfoot>

        <?php

        foreach($profile as $k => $v){
            //skip
            if(preg_match("/(password|id|username|email|activated|ban|ban_reason|last_login|last_ip|created|modified|memgroup)/i", $k)) continue;
           ?>
        <tr>
            <th><?php echo $this->lang->line('mem.90.'.$k); ?></th>
            <td><input type="text" name="<?php echo $k?>" value="<?php echo $v?>" /></td>
        </tr>
        <?php
        }?>
        <tr>
            <th colspan="2"><input type="submit" name="submit" value="submit" onclick="javascript:return confirm('<?php echo $this->lang->line("mem.91.update")?>')" /></th>

        </tr>

    </tfoot>
    </form>
<?php
$this->theme->view('_foot');
?>